import time

def get_gudong_info(mongo_instance, soup, cid, company):
    print('start 股东数据*******')
    imps = soup.find('div', id="_container_holder").find('tbody').find_all('tr') if soup.find('div',
                                                                                              id="_container_holder") else []
    items = {}
    for people in imps:
        ahrefs = people.find_all('a') if people.find('a') else []
        if ahrefs:
            try:
                company_name = ahrefs[0].text
                company_num = ahrefs[1].text.strip().strip('>')
                tds = people.find_all('td')
                money_bilv = tds[2].text
                money_renjiao = tds[3].find('span').text
                items = {'company': company, 'company_id': cid, 'name': company_name, 'company_num': company_num,
                         'company_num': company_num, 'money_bilv': money_bilv, 'money_renjiao': money_renjiao}
                items['create_at'] = int(time.time())
                items['update_at'] = items['create_at']
            except IndexError:
                print('Index Error')
            else:
                mongo_instance.gudong.update({'company_id': cid}, items, True)

    print('sucess 股东数据*******')